//
//  HomeViewController.m
//  BeautyBaoUnion
//
//  Created by 肖智 on 2016/10/24.
//  Copyright © 2016年 肖智. All rights reserved.
//

#import "HomeViewController.h"
#import "CircleController.h"
#import "VideoViewController.h"
#import "CardView.h"
@interface HomeViewController (){
    CardView *_cardView;
}

@end

@implementation HomeViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.navigationController.navigationBarHidden = NO;
//    self.view.backgroundColor = [UIColor colorWithHex:0xfaf7f2 alpha:1.0];
    self.view.backgroundColor = [UIColor whiteColor];


    
    _cardView = [[CardView alloc] initWithFrame:CGRectMake(0, 0, self.view.bounds.size.width, self.view.bounds.size.width*0.6+20)];
    [_cardView layoutItemWithData:@[@"a",@"b",@"c",@"d",@"e"]];
    [self.view addSubview:_cardView];
    

    UIButton *btn = [UIButton buttonWithType:UIButtonTypeCustom];
    btn.frame = CGRectMake(100, 400, 60, 30);
    btn.backgroundColor = [UIColor lightGrayColor];
    [btn addTarget:self action:@selector(beginAnimation) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:btn];
    // Do any additional setup after loading the view.
}
- (void)beginAnimation{
    VideoViewController *clt = [[VideoViewController alloc] init];
    [self presentViewController:clt animated:YES completion:^{
        
    }];
    
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
- (void)viewWillAppear:(BOOL)animated{
    [super viewWillAppear:animated];
}
/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
